﻿<%@ Page Language="C#" AutoEventWireup="true" Inherits="ZX.Web.UI.Controls.miniDataGrid" %>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title></title>
    <style>
        html, body {
            margin: 0;
            padding: 0;
            border: 0;
            width: 100%;
            height: 100%;
            overflow: hidden;
        }

        .col1 {
            float: left;
            width: 25%;
        }

        .col2 {
            float: left;
            width: 50%;
        }

        .query_table {
            width: 100%;
        }

        .label {
            width: 90px;
            text-align: right;
        }

        .exp {
            width: 60px;
        }

        .exp > select {
            width: 60px;
        }
    </style>
</head>
<script src="/SFramework/boot.js"></script>
<body style="margin: 0px; padding: 0px">
    <form id="form1" runat="server">
        <div style="width: 100%; height: 100%">
            <div class="mini-toolbar" style="border-bottom: 0; padding: 0px;">
                <table style="width: 100%;">
                    <tr>
                        <td style="width: 100%;">
                            <%=BtnItems %>
                        </td>
                        <td style="white-space: nowrap;"><a class="mini-button" iconcls="icon-expand" plain="true" onclick="showQuery()" id="btnHQuery">查询</a></td>
                        <td style="white-space: nowrap;">
                            <input type="checkbox" id="checkAndOr" /><span style="margin-top: -5px;">并集</span>
                            <input id="QueryContext" type="text" />
                            <a class="mini-button" onclick="fnQuciklyQuery()">查询</a>
                        </td>
                    </tr>
                </table>
                <div id="QueryItem" style="display: none;">
                    <%=QueryHtml %>
                    <div style="width: 99.9999%; text-align: center; border-top: #808080 1px solid; padding-top: 5px; padding-bottom: 5px; margin: 0px;">
                        <a class="mini-button" iconcls="icon_close" onclick="fnEmptyQuery()">清空</a><a class="mini-button" iconcls="icon_close" onclick="fnCloseQuery()">关闭</a><a class="mini-button" iconcls="icon_find" onclick="fnHightLevelQuery()">查询</a>
                    </div>
                </div>
            </div>
        </div>
        <div id="datagrid1" class="mini-datagrid" pagesize="20" allowresize="true" allowscroll="true" allowcelledit="<%=AllowEdit.ToString().ToLower()%>" allowcellselect="<%=AllowEdit.ToString().ToLower()%>" multiselect="true"
            editnextonenterkey="true" editnextrowcell="true" idfield="id" multiselect="true" url="../data/jsondata.aspx?entity=<%=EntityName%>&condition=<%=Condition %>&order=<%=Order%>&desc=<%=GetStringFromQueryString("desc","Yes") %>&datagrid=true" pagesize="15">
            <div property="columns">
                <div type="indexcolumn" width="25"></div>
                <div type="checkcolumn" width="25"></div>
                <%=DataFields %>
                <%--<div field="group_id" width="120" type="comboboxcolumn" headeralign="center" allowsort="true">类型
                    <input property="editor" class="mini-combobox" style="width:100%;" data="FeeType" />
                </div>--%>
            </div>

        </div>
    </form>
</body>

<script type="text/javascript">
    const_entityID = "<% =EntityId %>",    //实体ID名称
    const_entityName = "<% =EntityName %>",//实体名称
    const_EditEntity = "<% =EditEntity %>",//编辑实体名
    const_functionId   ="<% =FunctionID %>",//自定义条件
    const_Order ="<% =Order %>",           //排序  
    const_UserId = "<% = UserId %>",       // 
    const_UserName =  "<% =UserName %>",  

    const_QueryField="<% =QuciklyQueryFields %>",
    const_CustomCondition = encodeURI("<% =DefineCondition %>"),//查询方案条件
    const_Condition = encodeURI("<% =Condition %>"),//
    const_PageTitle=encodeURI("<% =PageTitle %>"),
    _openWindowHeight=<%=EditWindowHeight%>,
    _openWindowWidth=<%=EditWindowWidth%>;

    <% =ColumnDataSource%>

</script>

<script type="text/javascript">
    $("#datagrid1").width($(document).width());
    $("#datagrid1").height($(document).height() - 37);
      
    mini.parse();
    var grid= mini.get("datagrid1")
    //debugger
    grid.load();
    //$("input[id^='code']");//id属性以code开始的所有input标签 
    //$("input[id$='code']");//id属性以code结束的所有input标签 
    //$("input[id*='code']");//id属性包含code的所有input标签 
    //grid.frozenColumns (3,4);
</script>

<script>
    <% =List_self_script %>
</script>
<script src="../../Scripts/datagrid/list.common.button.js"  type="text/javascript"></script>
<script src="../../Scripts/common/jquery.action.js"  type="text/javascript"></script>
<script src="../../Scripts/ctrls/jquery.fixed.dialog.js" type="text/javascript"></script>
<script src="../../Scripts/ctrls/jquery.fixed.windows.js" type="text/javascript"></script>
<script src="../../Scripts/app/list/model.<% =EntityName %>.js" type="text/javascript"></script>
</html>
